<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:p="http://primefaces.org/ui">

<ui:composition template="/resources/squelette/squelette.xhtml">

	<ui:define name="content">
		<h:outputText value="Une erreur inattendue s'est produite. Merci de contacter l'administrateur si le problème persiste." class="error font-size-xl" />
		<p:panel class="error margin-top-s">
			<h:panelGrid columns="2">
				<p:outputLabel value="Navigateur:" />
				<h:outputText value="#{header['user-agent']}" />
				<p:outputLabel value="Adresse IP:" />
				<h:outputText value="#{request.remoteAddr}" />
				<p:outputLabel value="Page" />
				<h:outputLink value="#{request.requestURI}">
					<h:outputText value="#{request.requestURI}" />
				</h:outputLink>
				<p:outputLabel value="Requête AJAX" />
				<h:outputText value="#{facesContext.partialViewContext.ajaxRequest ? 'Oui' : 'Non'}" />
				<p:outputLabel value="Type d'erreur" />
				<h:outputText value="#{facesContext.externalContext.requestMap['exception.class']}" />
				<p:outputLabel value="Message d'erreur:" />
				<h:outputText value="#{facesContext.externalContext.requestMap['exception.message']}" />
			</h:panelGrid>
		</p:panel>
		<p:fieldset legend="Stacktrace" class="margin-top-s">
			<ui:repeat value="#{facesContext.externalContext.requestMap['exception.stacktrace']}" var="trace">
				<div>
					<h:outputText value="#{trace}" escape="false" />
				</div>
			</ui:repeat>
		</p:fieldset>
	</ui:define>

</ui:composition>

</html>